﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="work_plan.aspx.cs" Inherits="AnyOffice.general.work_plan.show.work_plan" %>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
<HTML>
	<HEAD>
		<title></title>
		
		<meta name="CODE_LANGUAGE" Content="C#">
		<meta name="vs_defaultClientScript" content="JavaScript">
		<meta name="vs_targetSchema" content="http://schemas.microsoft.com/intellisense/ie5">
		<script type="text/javascript" language="JavaScript">                             
		function open_workplan(plan_id)
		{
//			URL="../read_workplan.aspx?plan_id="+plan_id;
//			myleft=(screen.availWidth-600)/2;
//			window.open(URL,"read_notify","height=450,width=600,status=1,toolbar=no,menubar=no,location=no,scrollbars=yes,top=150,left="+myleft+",resizable=yes");
			var mwidth = "600";
			var mheight = "450";
			var loc_x = parseInt((window.screen.width - mwidth) / 2);
			var loc_y = parseInt((window.screen.height - mwidth) / 2);

			var _oParameter = new Object();
			_oParameter.dialogTitle = "项目进度";
			_oParameter.openFile = "../read_workplan.aspx?plan_id=" + plan_id + "&num=" + Math.random();

			window.showModalDialog('shDialog.htm', _oParameter, 'dialogHeight:' + mheight + 'px;dialogWidth:' + mwidth + 'px;dialogLeft:' + loc_x + ';dialogTop:' + loc_y + ';help:no;status:no;scroll:yes;titlebar:no;toolbar:no');
  
     
        }                                                   
		</script>
	</HEAD>
	<body class="bodycolor" topMargin="5">
		<form id="Form1" method="post" runat="server">
          <div class="main_div">
			<table border="0" width="100%" cellspacing="0" cellpadding="3" class="small">
				<tr>
					<td class="Big"><img src="/images/menu/work_plan.gif" WIDTH="20" HEIGHT="20" align="absMiddle"><span class="big3">
							全体项目进度</span><br>
					</td>
				</tr>
			</table>						
			<asp:Repeater id="rptAllDept" runat="server" EnableViewState="False">			
			<HeaderTemplate>
			<br>
			<table border="0" cellspacing="1" width="100%" class="small" bgcolor="#000000" cellpadding="3">
			<tr class="TableHeader">
					<td nowrap align="center">项目名称</td>
					<td nowrap align="center">开始日期</td>
					<td nowrap align="center">预计完成日期</td>
					<td nowrap align="center">项目类别</td>
					<td nowrap align="center">发布范围</td>
					<td nowrap align="center">负责人</td>
					<TD noWrap align="center">进度</TD>
					<td nowrap align="center">状态</td>
				</tr>
			</HeaderTemplate>
			<ItemTemplate>
			<tr class="TableLine1">
					<td><a href="javascript:open_workplan('<%#Eval("PlanId")%>');"><%#Eval("Name")%></a></td>
					<td nowrap align="center"><%# Eval("BeginDate") != DBNull.Value ? Convert.ToDateTime(Eval("BeginDate")).ToString("yyyy-MM-dd"):""%></td>
					<td nowrap align="center"><%# Eval("EndDate") != DBNull.Value ? Convert.ToDateTime(Eval("EndDate")).ToString("yyyy-MM-dd"):""%></td>
					<td nowrap align="center"><%#Eval("TypeName")%></td>
					<td nowrap align="center">全体部门</td>
					<td nowrap align="center"><%#Eval("UserName")%></td>
					<td nowrap align="center" width="80">
							<table width="70px" border="0" cellspacing="0" cellpadding="0" style="BORDER-RIGHT: #000000 1px solid; BORDER-TOP: #000000 1px solid; BORDER-LEFT: #000000 1px solid; BORDER-BOTTOM: #000000 1px solid; HEIGHT: 8px" title='<%#Convert.ToInt32(Eval("CompletedPercent"))*10%>%'>
								<tr>
									<td bgcolor='green' width='<%#Convert.ToInt32(Eval("CompletedPercent"))*10%>%'></td>
									<td bgcolor="#ffffff" width='<%#100-Convert.ToInt32(Eval("CompletedPercent"))*10%>%'></td>
								</tr>
							</table>
					</td>
					<td nowrap align="center"><%#GetStatusDesc(Convert.ToInt32(Eval("Status")))%></td>
				</tr>
			</ItemTemplate>
			<AlternatingItemTemplate>
				<tr class="TableLine2">
					<td><a href="javascript:open_workplan('<%#Eval("PlanId")%>');"><%#Eval("Name")%></a></td>
					<td nowrap align="center"><%# Eval("BeginDate") != DBNull.Value ? Convert.ToDateTime(Eval("BeginDate")).ToString("yyyy-MM-dd"):""%></td>
					<td nowrap align="center"><%# Eval("EndDate") != DBNull.Value ? Convert.ToDateTime(Eval("EndDate")).ToString("yyyy-MM-dd"):""%></td>
					<td nowrap align="center"><%#Eval("TypeName")%></td>
					<td nowrap align="center">全体部门</td>
					<td nowrap align="center"><%#Eval("UserName")%></td>
					<td nowrap align="center" width="80">
							<table width="70px" border="0" cellspacing="0" cellpadding="0" style="BORDER-RIGHT: #000000 1px solid; BORDER-TOP: #000000 1px solid; BORDER-LEFT: #000000 1px solid; BORDER-BOTTOM: #000000 1px solid; HEIGHT: 8px" title='<%#Convert.ToInt32(Eval("CompletedPercent"))*10%>%'>
								<tr>
									<td bgcolor='green' width='<%#Convert.ToInt32(Eval("CompletedPercent"))*10%>%'></td>
									<td bgcolor="#ffffff" width='<%#100-Convert.ToInt32(Eval("CompletedPercent"))*10%>%'></td>
								</tr>
							</table>
					</td>
					<td nowrap align="center"><%#GetStatusDesc(Convert.ToInt32(Eval("Status")))%></td>
				</tr>
			</AlternatingItemTemplate>
			<FooterTemplate>
			</table>
			</FooterTemplate>
			</asp:Repeater>
			<asp:Literal id="litAllDept" runat="server"></asp:Literal>	
			
			<br>
			<table border="0" width="100%" cellspacing="0" cellpadding="3" class="small">
				<tr>
					<td class="Big"><img src="/images/menu/work_plan.gif" WIDTH="20" HEIGHT="20" align="absMiddle"><span class="big3">
							&nbsp;机构项目进度</span><br>
					</td>
				</tr>
			</table>				
			<asp:Repeater id="rptDept" runat="server" EnableViewState="False">
			<HeaderTemplate>
			<br>
			<table border="0" cellspacing="1" width="100%" class="small" bgcolor="#000000" cellpadding="3">
			<tr class="TableHeader">
					<td nowrap align="center">项目名称</td>
					<td nowrap align="center">开始日期</td>
					<td nowrap align="center">预计完成日期</td>
					<td nowrap align="center">项目类别</td>
					<td nowrap align="center">发布范围</td>
					<td nowrap align="center">负责人</td>
					<TD noWrap align="center">进度</TD>
					<td nowrap align="center">状态</td>
				</tr>
			</HeaderTemplate>
			<ItemTemplate>
			<tr class="TableLine1">
					<td><a href="javascript:open_workplan('<%#Eval("PlanId")%>');"><%#Eval("Name")%></a></td>
					<td nowrap align="center"><%# Eval("BeginDate") != DBNull.Value ? Convert.ToDateTime(Eval("BeginDate")).ToString("yyyy-MM-dd"):""%></td>
					<td nowrap align="center"><%# Eval("EndDate") != DBNull.Value ? Convert.ToDateTime(Eval("EndDate")).ToString("yyyy-MM-dd"):""%></td>
					<td nowrap align="center"><%#Eval("TypeName")%></td>
					<td><%#Eval("ToName")%></td>
					<td nowrap align="center"><%#Eval("UserName")%></td>
					<td nowrap align="center" width="80">
							<table width="70px" border="0" cellspacing="0" cellpadding="0" style="BORDER-RIGHT: #000000 1px solid; BORDER-TOP: #000000 1px solid; BORDER-LEFT: #000000 1px solid; BORDER-BOTTOM: #000000 1px solid; HEIGHT: 8px" title='<%#Convert.ToInt32(Eval("CompletedPercent"))*10%>%'>
								<tr>
									<td bgcolor='green' width='<%#Convert.ToInt32(Eval("CompletedPercent"))*10%>%'></td>
									<td bgcolor="#ffffff" width='<%#100-Convert.ToInt32(Eval("CompletedPercent"))*10%>%'></td>
								</tr>
							</table>
					</td>
					<td nowrap align="center"><%#GetStatusDesc(Convert.ToInt32(Eval("Status")))%></td>
				</tr>
			</ItemTemplate>
			<AlternatingItemTemplate>
				<tr class="TableLine2">
					<td><a href="javascript:open_workplan('<%#Eval("PlanId")%>');"><%#Eval("Name")%></a></td>
					<td nowrap align="center"><%# Eval("BeginDate") != DBNull.Value ? Convert.ToDateTime(Eval("BeginDate")).ToString("yyyy-MM-dd"):""%></td>
					<td nowrap align="center"><%# Eval("EndDate") != DBNull.Value ? Convert.ToDateTime(Eval("EndDate")).ToString("yyyy-MM-dd"):""%></td>
					<td nowrap align="center"><%#Eval("TypeName")%></td>
					<td><%#Eval("ToName")%></td>
					<td nowrap align="center"><%#Eval("UserName")%></td>
					<td nowrap align="center" width="80">
							<table width="70px" border="0" cellspacing="0" cellpadding="0" style="BORDER-RIGHT: #000000 1px solid; BORDER-TOP: #000000 1px solid; BORDER-LEFT: #000000 1px solid; BORDER-BOTTOM: #000000 1px solid; HEIGHT: 8px" title='<%#Convert.ToInt32(Eval("CompletedPercent"))*10%>%'>
								<tr>
									<td bgcolor='green' width='<%#Convert.ToInt32(Eval("CompletedPercent"))*10%>%'></td>
									<td bgcolor="#ffffff" width='<%#100-Convert.ToInt32(Eval("CompletedPercent"))*10%>%'></td>
								</tr>
							</table>
					</td>
					<td nowrap align="center"><%#GetStatusDesc(Convert.ToInt32(Eval("Status")))%></td>
				</tr>
			</AlternatingItemTemplate>
			<FooterTemplate>
			</table>
			</FooterTemplate>
			</asp:Repeater>
			<asp:Literal id="litDept" runat="server"></asp:Literal>
			<br>
            </div>
		</form>
	</body>
</HTML>
